A packet-based network includes multiple nodes that are coupled together to facilitate the forwarding of traffic from one node to some subset of the other nodes. Nodes that intelligently forward traffic between these nodes are often referred to as routers, bridges, or switches. Lookups are performed frequently in the process of handling network traffic. In a lookup, information from incoming packets, such as header information, is used to compare against information stored in a lookup table to determine how the packet should be handled. In the process of handling network traffic, a lookup may entail using information from one or more protocol layers. The International Standards Organization (ISO) defines the layers in the Open System Interconnection (OSI) model.
A router must typically be configured before routing packets. Configuring a router typically entails entering a set of configuration commands and waiting for the router to execute the commands. Configuration commands may include, for example, commands to set a hostname (e.g., “hostname name”) and commands to set bandwidth (e.g., “bandwidth 128”). Several proprietary configuration command sets are used. The syntax of any given command depends upon the proprietary configuration command set used for a particular router. The configuration commands may be entered one-by-one using a graphical user interface (GUI) or in a batch using a text file that is received at the router via a data interface. When a configuration command is successfully executed (i.e., is accepted by the router), data associated with the configuration command is loaded into a running configuration (“config”) file on the router. The running config file includes each active configuration command. The router may or may not provide feedback related to the successful execution of configuration commands, but routers typically have “show config” commands that allow an administrator to check the contents of the running config file.
When a configuration command is unsuccessfully executed at a router, the configuration command is discarded. An administrator is typically informed of the failure of the configuration command through a craft interface or an error log that is output from the router. An administrator may find it difficult to figure out which commands failed due to the limited amount of information that may be derived from a craft interface and incomplete error logs. Nevertheless, in part due to the limited resources, comprehensive configuration tools are typically not available on a router. Accordingly, if there is a change of conditions at the router that would result in successful execution of a configuration command that previously failed, the administrator may not be aware of the change. And even if the administrator consults the error logs or otherwise becomes aware of the change of conditions, the administrator must reenter the configuration command, or commands.
In view of the need to respond to changes in conditions at a router, what is needed is a technique for managing configuration state within a network switch.